package com.jimmy.ioc.config;

import com.jimmy.ioc.bean.Person;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.PropertySource;
import org.springframework.stereotype.Component;

/**
 * @version 1.0
 * @ ClassName MainConfigOfProterties
 * <p> TODO
 * @ author JIMMY
 * @ Date 2020/12/7 0007 下午 3:52
 */
@Configuration
//@ComponentScan("com.jimmy.ioc")
@PropertySource("classpath:person.properties")    //加载外部文件
public class MainConfigOfProterties {
    @Bean
    public Person person(){
        return new Person();
    }
}
